home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
TPUG - Toronto PET Users Group
/
TPUG Users Group CD
/
TPUG Users Group CD.iso
/
AMIGA
/
(A)TB
/
(A)TBX.ADF
/
ClockDJv5.04
/
rexx
/
PointCopy.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1992-03-18
|
998b
|
38 lines
/* Multiple file copy */
options results
address clockdj
setcedhide ""
setcedshow ""
setcedtitle "Select files to copy"
setceddir "VD0:"
setcedfile ""
cedextendedrequester
files = result;if files = "" then exit
setceddir "RAM:"
setcedtitle "Select destination directory"
cedrequesterdir
dir = result;if dir = "" then exit
win = "con:s*/0/50/640/350//cd/02\r\c"
if ~open('console',win) then exit /* Window for all activity */
call writeln 'console','9b'x'1;32;40mCopy:'||'9b'x'0;31;40m'
call writech 'console',files
call writeln 'console','9b'x'1;32;40mTo: '||'9b'x'0;31;40m'||dir
POPREQUESTER 'Do you really want to copy these?'
if result = no then exit
address command
if index(files,'0a'x) = 0 then do
"runwsh >nil: copy >nil:" '"'files'"' "to" dir "clone"
exit
end
pos1 = 1
do forever
pos2 = index(files,'0a'x,pos1+1)
if pos2 = 0 then do
say 'All done.';exit
end
else nop
"runwsh >nil: copy >nil:" '"'substr(files,pos1,(pos2-pos1))'"' "to" dir "clone"
pos1 = pos2+1
end